// VarTable.h : VarTable is used to keep all the variables that appeared in the program.
// Author: Achyut P Balaji
//
#ifndef VAR_TABLE_H
#define VAR_TABLE_H

#include"SPA_Data_Types.h"

using namespace std;

typedef string VAR;
typedef int NOOFCONSTANTS;
typedef NUMERIC_EXPR_TYPE TYPES;

class VarTable {
private:
	vector<VAR> variableList;
	vector<TYPES> variableType;
	NOOFCONSTANTS constantNo;
	static VarTable *obj;
	VarTable();
public:
	static VarTable* getInstance();
	VAR_INDEX insertVar (VAR v,NUMERIC_EXPR_TYPE type);													
	VAR getVarName (VAR_INDEX ind);
	VAR_INDEX getVarIndex (VAR v);
	INTEGER getVarSize();
	INTEGER getTotalSize();
	NUMERIC_EXPR_TYPE getVarType(VAR_INDEX ind);
};
#endif